﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<IEnumerable<MVCWeb.Models.TvModel>>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
	ViewResults
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">

    <h2>ViewResults</h2>

    <table>
        <tr>
            <th></th>

            <th>
                Product ID
            </th>
            <th>
                Display
            </th>
            <th>
                Make
            </th>
            <th>
                Size 
            </th>
            <th>
                Resolution
            </th>
            <th>
                Refresh Rate
            </th>
            <th>
                Price
            </th>
            <th>
                Free Shipping
            </th>
        </tr>

    <% foreach (var item in Model) { %>
    
        <tr>
            <td>
                <%: Html.ActionLink("Add To Cart", "CreateItem", "Order", new { pid = item.product_id }, null) %> 
             
            </td>
            <td>
                <%: item.product_id %>
            </td>
            <td>
                <%: item.display_type %>
            </td>
            <td>
                <%: item.make_type %>
            </td>
            <td>
                <%: item.size_type %>
            </td>
            <td>
                <%: item.res_type %>
            </td>
            <td>
                <%: item.refresh_type %>
            </td>
            <td>
                <%: String.Format("{0:F}", item.price) %>
            </td>
            <td>
                <%: item.ship_type %>
            </td>
        </tr>
    
    <% } %>

    </table>


</asp:Content>

